package com.ruoyi.prescription.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;

/**
 * 处方明细对象 prescription_detail
 * 
 * @author ruoyi
 * @date 2025-04-12
 */
public class PrescriptionDetail extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键id */
    private Long id;

    /** 处方id */
    @Excel(name = "处方id")
    private Long prescriptionId;

    /** 药品id */
    @Excel(name = "药品id")
    private Long medicationId;

    /** 用药剂量 */
    @Excel(name = "用药剂量")
    private String dosage;

    /** 药品总量 */
    @Excel(name = "药品总量")
    private Long quantity;

    /** 药品单价 */
    @Excel(name = "药品单价")
    private BigDecimal price;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setPrescriptionId(Long prescriptionId) 
    {
        this.prescriptionId = prescriptionId;
    }

    public Long getPrescriptionId() 
    {
        return prescriptionId;
    }
    public void setMedicationId(Long medicationId) 
    {
        this.medicationId = medicationId;
    }

    public Long getMedicationId() 
    {
        return medicationId;
    }
    public void setDosage(String dosage)
    {
        this.dosage = dosage;
    }

    public String getDosage()
    {
        return dosage;
    }
    public void setQuantity(Long quantity) 
    {
        this.quantity = quantity;
    }

    public Long getQuantity() 
    {
        return quantity;
    }
    public void setPrice(BigDecimal price) 
    {
        this.price = price;
    }

    public BigDecimal getPrice() 
    {
        return price;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("prescriptionId", getPrescriptionId())
            .append("medicationId", getMedicationId())
            .append("dosage", getDosage())
            .append("quantity", getQuantity())
            .append("price", getPrice())
            .toString();
    }
}
